package org.hpin.asset.service;

import org.hpin.asset.dao.SuppliersDao;
import org.hpin.asset.entity.Suppliers;
import org.hpin.common.core.orm.BaseService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@Service(value = "org.hpin.asset.service.SuppliersService")
@Transactional(rollbackFor = Exception.class)
public class SuppliersService extends BaseService {
	@Autowired()
	private SuppliersDao dao;
	public void delete(String[] ids){
		for(int  i = 0 ; i<ids.length ; i++){
			Suppliers suppliers = (Suppliers) dao.findById(Suppliers.class, ids[i]);
			suppliers.setIsDeleted(1);
			dao.update(suppliers);
		}
	}

}
